<?php
/**
 * lsys orm
 * @author     Lonely <shan.liu@msn.com>
 * @copyright  (c) 2017 Lonely <shan.liu@msn.com>
 * @license    http://www.apache.org/licenses/LICENSE-2.0
 */
namespace LSYS\ORMCache\Lists;
use LSYS\ORM\Entity;
interface CacheGet {
	/**
	 * @param array $where
	 * @param string $sort
	 * @param number $offset
	 * @param number $limit
	 * @return \LSYS\ORM\Cache\Result
	 */
	 public function lists_get(array $where,$sort,$offset,$limit);
	/**
	 * @param array $where
	 * @return int|false
	 */
	 public function lists_total_get(array $where);
	/**
	 * add entity to list
	 * @param Entity $entity
	 */
	 public function lists_insert(Entity $entity);
	/**
	 * delete item form list
	 * @param string $pk
	 */
	 public function lists_delete(Entity $entity);
	/**
	 * delete item form list
	 * @param string $pk
	 */
	 public function lists_update(Entity $new_entity);
}